package com.wyzz.hr.pojo.base;

import java.io.Serializable;
import java.util.Date;

import com.wyzz.hr.pojo.Client;

public abstract class BaseClient implements Serializable {

	public BaseClient() {
		hashCode = 0x80000000;
		clientServiceMonths = Integer.valueOf(0);
		clientServiceTimes = Integer.valueOf(0);
		initialize();
	}

	public BaseClient(String id) {
		hashCode = 0x80000000;
		clientServiceMonths = Integer.valueOf(0);
		clientServiceTimes = Integer.valueOf(0);
		setId(id);
		initialize();
	}

	public BaseClient(String id, String clientLimit, String clientRemarks) {
		hashCode = 0x80000000;
		clientServiceMonths = Integer.valueOf(0);
		clientServiceTimes = Integer.valueOf(0);
		setId(id);
		setClientLimit(clientLimit);
		setClientRemarks(clientRemarks);
		initialize();
	}

	protected void initialize() {
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
		hashCode = 0x80000000;
	}

	public String getClientId() {
		return clientId;
	}

	public void setClientId(String clientId) {
		this.clientId = clientId;
	}

	public String getClientName() {
		return clientName;
	}

	public void setClientName(String clientName) {
		this.clientName = clientName;
	}

	public String getClientShortName() {
		return clientShortName;
	}

	public void setClientShortName(String clientShortName) {
		this.clientShortName = clientShortName;
	}

	public String getClientAddress() {
		return clientAddress;
	}

	public void setClientAddress(String clientAddress) {
		this.clientAddress = clientAddress;
	}

	public String getClientZip() {
		return clientZip;
	}

	public void setClientZip(String clientZip) {
		this.clientZip = clientZip;
	}

	public String getClientPhone() {
		return clientPhone;
	}

	public void setClientPhone(String clientPhone) {
		this.clientPhone = clientPhone;
	}

	public String getClientFax() {
		return clientFax;
	}

	public void setClientFax(String clientFax) {
		this.clientFax = clientFax;
	}

	public String getClientEmail() {
		return clientEmail;
	}

	public void setClientEmail(String clientEmail) {
		this.clientEmail = clientEmail;
	}

	public String getClientContactName() {
		return clientContactName;
	}

	public void setClientContactName(String clientContactName) {
		this.clientContactName = clientContactName;
	}

	public Date getClientActivateTime() {
		return clientActivateTime;
	}

	public void setClientActivateTime(Date clientActivateTime) {
		this.clientActivateTime = clientActivateTime;
	}

	public Integer getClientServiceMonths() {
		return clientServiceMonths;
	}

	public void setClientServiceMonths(Integer clientServiceMonths) {
		this.clientServiceMonths = clientServiceMonths;
	}

	public Integer getClientServiceTimes() {
		return clientServiceTimes;
	}

	public void setClientServiceTimes(Integer clientServiceTimes) {
		this.clientServiceTimes = clientServiceTimes;
	}

	public Integer getClientStatus() {
		return clientStatus;
	}

	public void setClientStatus(Integer clientStatus) {
		this.clientStatus = clientStatus;
	}

	public String getClientLimit() {
		return clientLimit;
	}

	public void setClientLimit(String clientLimit) {
		this.clientLimit = clientLimit;
	}

	public String getClientRemarks() {
		return clientRemarks;
	}

	public void setClientRemarks(String clientRemarks) {
		this.clientRemarks = clientRemarks;
	}

	public boolean equals(Object obj) {
		if (null == obj)
			return false;
		if (!(obj instanceof Client))
			return false;
		Client client = (Client) obj;
		if (null == getId() || null == client.getId())
			return false;
		else
			return getId().equals(client.getId());
	}

	public int hashCode() {
		if (0x80000000 == hashCode) {
			if (null == getId())
				return super.hashCode();
			String hashStr = (new StringBuilder()).append(getClass().getName())
					.append(":").append(getId().hashCode()).toString();
			hashCode = hashStr.hashCode();
		}
		return hashCode;
	}

	public String toString() {
		return super.toString();
	}

	public static String REF = "Client";
	public static String PROP_CLIENT_ACTIVATE_TIME = "clientActivateTime";
	public static String PROP_CLIENT_REMARKS = "clientRemarks";
	public static String PROP_CLIENT_EMAIL = "clientEmail";
	public static String PROP_CLIENT_NAME = "clientName";
	public static String PROP_CLIENT_ADDRESS = "clientAddress";
	public static String PROP_CLIENT_PHONE = "clientPhone";
	public static String PROP_CLIENT_SERVICE_TIMES = "clientServiceTimes";
	public static String PROP_CLIENT_STATUS = "clientStatus";
	public static String PROP_CLIENT_SERVICE_MONTHS = "clientServiceMonths";
	public static String PROP_CLIENT_ID = "clientId";
	public static String PROP_CLIENT_SHORT_NAME = "clientShortName";
	public static String PROP_CLIENT_FAX = "clientFax";
	public static String PROP_CLIENT_CONTACT_NAME = "clientContactName";
	public static String PROP_CLIENT_LIMIT = "clientLimit";
	public static String PROP_CLIENT_ZIP = "clientZip";
	public static String PROP_ID = "id";
	private int hashCode;
	private String id;
	private String clientId;
	private String clientName;
	private String clientShortName;
	private String clientAddress;
	private String clientZip;
	private String clientPhone;
	private String clientFax;
	private String clientEmail;
	private String clientContactName;
	private Date clientActivateTime;
	private Integer clientServiceMonths;
	private Integer clientServiceTimes;
	private Integer clientStatus;
	private String clientLimit;
	private String clientRemarks;

}
